cmake_minimum_required(VERSION 3.23)
project(DataStructure)

set(CMAKE_CXX_STANDARD 14)

# Compile static library
file(GLOB_RECURSE SRC_HASHTABLE HashTable/*)
add_library(hashtable STATIC ${SRC_HASHTABLE})

file(GLOB_RECURSE SRC_TREES Tree/*)
add_library(trees STATIC ${SRC_TREES})

file(GLOB_RECURSE SRC_DSETS DisjointSets/*)
add_library(dsets STATIC ${SRC_DSETS})

file(GLOB_RECURSE SRC_GRAPHS Graph/*)
add_library(graph STATIC ${SRC_GRAPHS})

file(GLOB_RECURSE SRC_UTILS utils/*)

include_directories(include)
aux_source_directory(source SRC)

# Compile executable file
add_executable(DataStructure main.cpp ${SRC} ${SRC_UTILS})
target_link_libraries(DataStructure hashtable trees dsets graph)
